//
//  FotoMare.h
//  iDent
//
//  Created by Marius Corega on 7/15/09.
//  Copyright 2009 Marius Corega. All rights reserved.
//

#import <Cocoa/Cocoa.h>
//#import <QuartzCore/QuartzCore.h>

#import "Poze.h"

@class CIImage;
@class CIFilter;
@class CIContext;


@interface FotoMare : NSView {

	CIImage *image;
	NSData *imagedata;
	CIFilter *filter;
	
	
	IBOutlet NSArrayController *pozeAC;
	
	float exposureValue;
	float zoomValue;
	float brightnessValue;
	float contrastValue;
	float saturationValue;
	float rotationValue;

 
	CGPoint origin;
	CGPoint mouseinit;
	
	IBOutlet NSWindow *toolWindow;
	IBOutlet NSSlider *exposureSlider;
	IBOutlet NSSlider *brightnessSlider;
	IBOutlet NSSlider *contrastSlider;
	IBOutlet NSSlider *saturationSlider;
	IBOutlet NSSlider *rotationSlider;
	IBOutlet NSSlider *zoomSlider;
	
	IBOutlet NSPopUpButton *tipFotoPB;
	IBOutlet NSDatePicker *dataFotoDP;
	IBOutlet NSTextField *descriereFotoTB;
	
	bool flipHorizontal, flipVertical;
	
}

-(float) exposureValue;
-(float) zoomValue;
-(float) brightnessValue;
-(float) contrastValue;
-(float) saturationValue;
-(float) rotationValue;
-(CGPoint) origin;
-(int) tipFoto;
-(NSString*) descriereFoto;
-(NSString*) dataFoto;

-(void) setExposureValue:(float) val;
-(void) setZoomValue:(float) val;
-(void) setSaturationValue:(float) val;
-(void) setRotationValue:(float) val;
-(void) setBrightnessValue:(float) val;
-(void) setContrastValue:(float) val;
-(void) setOriginX:(int) val;
-(void) setOriginY:(int) val;
-(void) setTipFoto:(int) val;
-(void) setDescriereFoto:(NSString*) str;
-(void) setDataFoto:(NSString*) str;

-(void) setFlipHorizontal:(bool)val;
-(void) setFlipVertical:(bool)val;

-(void) setImageData:(NSData*) img;
-(void) setImage:(NSImage*) img;
-(void) setNoImage;

-(void) exposureChanged:(id)sender;
-(IBAction) zoomChanged:(id)sender;
-(IBAction) brightnessChanged:(id)sender;
-(IBAction) contrastChanged:(id)sender;
-(IBAction) saturationChanged:(id)sender;
-(IBAction) rotationChanged:(id)sender;

-(IBAction) showToolWindow:(id)sender;

-(IBAction) flipH:(id)sender;
-(IBAction) flipV:(id)sender;


-(IBAction)redrawImage:(id)sender;
@end
